package syn;

/**
 * @author ：黄淼淳
 * @description：
 * @date ：2021/12/12 16:38
 */
public class Test {
    public static void main(String[] args) {
        Phone phone = new Phone();
        Phone phone1 = new Phone();
        new Thread(() -> {
            phone1.sendHello(Thread.currentThread().getName());
        }, "刘二").start();
        new Thread(() -> {
            phone.sendEmail(Thread.currentThread().getName());
        }, "张三").start();
        new Thread(() -> {
            phone.sendSMS(Thread.currentThread().getName());
        }, "王五").start();
        new Thread(() -> {
            Phone.sendHello(Thread.currentThread().getName());
        }, "李四").start();
    }
}
